﻿using System.Windows;
using MvvmCodeReduction.Model;
using MvvmCodeReduction.Presenter;
using MvvmCodeReduction.View.CodeBehind;
using MvvmCodeReduction.View.MVP;

namespace MvvmCodeReduction.View
{
    /// <summary>
    /// Interaction logic for MainWindow.xaml
    /// </summary>
    public partial class MainWindow : Window
    {
        public MainWindow()
        {
            InitializeComponent();
        }

        private void ShowCustomers_Click(object sender, RoutedEventArgs e)
        {
            new CustomersCodeBehind(RepositoryStub.Instance).Show();
        }

        private void ShowCustomersMVVM_Click(object sender, RoutedEventArgs e)
        {
            new CustomersMVVM().Show();
        }

        private void ShowCustomersMVP_Click(object sender, RoutedEventArgs e)
        {
            CustomersMVP view = new CustomersMVP();
            CustomersPresenter presenter = new CustomersPresenter(view, RepositoryStub.Instance);
            view.Show();
        }
    }
}
